How to get complementary function